Repository navigation
feat(root): one stack standard for the ops consoles, Bun catalog and stack check - #5275
Conversation
|
This change is part of the following stack: Change managed by git-spice. |
|
Automatic reviews are disabled for this repository. Configure in Code Review Settings. |
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
@coderabbitai review Automated re-review request for |
0001412 to
3c2d73a
Compare
Action not completed
|
|
@codex review Automated re-review request for |
|
Codex Review: Didn't find any major issues. You're on a roll. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
db0b137 to
7cfe224
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7cfe224c77
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
7cfe224 to
bd8b5fd
Compare
0d63ffb to
02c03dd
Compare
…stack check Why The ten first-party ops consoles shared React, Vite, TypeScript, Vitest, Zod and console-ui, then diverged below that: React Router beside TanStack Router and hand-rolled routing, REST beside tRPC, raw SQLite beside Prisma. Nothing wrote the standard down, kept versions aligned, or stopped a new console from starting from a bare server. What - Root Bun `catalog` of the shared library versions (nothing upgraded); the ten consoles, console-ui and ops-model declare them as `catalog:`. - Renovate reads the catalog through a JSONata custom manager (its npm manager does not read `catalog`); `check-floating-deps` accepts `catalog:`. - `bun run check-console-stack` (wired into package.json, turbo and verify): required libraries, banned alternatives, `catalog:` use, Rust-console exceptions, and a per-app allowlist of today's deviations that can only shrink. - Mail, Flags and Feeds lint with the React rules; their `useEffect` calls are replaced with ref callbacks, `<title>` and derived state. - `new-service.ts --console` scaffolds the standard stack. - Wiki reference `console-stack`, the why in the hosted-service model page, the how-to flag, and one line in AGENTS.md. Verification - `bun install --frozen-lockfile`; `bunx turbo run typecheck lint test` over the ten consoles, console-ui and ops-model: 56 of 56 tasks pass. - check-console-stack, check-floating-deps, renovate-hints and the Renovate, scaffolder and root-scripts suites pass; knip shows only the existing `#generated` unresolved imports; jscpd ratchet passes; wiki builds. - A scaffolded `--console` package typechecks, lints, tests, builds and serves `/healthz`, `/trpc` and the client. - Renovate extraction of the catalog verified with a local `renovate --dry-run=extract`. - Not run: live Renovate PR creation; deployment (no runtime change). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…them Why CU2–4 (#5430) added @tanstack/react-table and @tanstack/react-form to console-ui (and react-form to Hub). The stack standard kept both in CATALOG_PENDING until a package declared them, and allowlisted console-ui as "missing" them; both entries are now stale and the stack check fails. What - Root catalog gains @tanstack/react-table ^9.3.1 and @tanstack/react-form ^1.33.6, the versions CU2–4 declared; console-ui and Hub use catalog:. - CATALOG_PENDING is empty and console-ui's two "missing" allowlist entries are gone; the wiki's "outside the catalog" table drops their row. Verification - `bun install --frozen-lockfile` passes; `bun run check-console-stack`: OK. - `bunx turbo run typecheck test lint --filter=@shepherdjerred/root-scripts --filter=@shepherdjerred/console-ui --filter=@shepherdjerred/alert-dashboard`: 34/34. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
02c03dd to
6931cbf
Compare
Why Review of #5275 (codex P1): packages/docs/wiki/AGENTS.md requires every claim about the system to link the source file that proves it, and the console-stack reference named its sources only as inline code. What - Links the root package.json (catalog), renovate.json (catalog manager), scripts/checks/check-console-stack.ts, scripts/checks/console-stack-rules.ts and the scaffolder scripts/misc/new-service-console.ts. Verification - package.json and renovate.json return 200 on main; the three scripts this PR adds return 200 on the pushed console-stack-standard branch and resolve on main once it merges (rechecked after merge). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Why
The ten first-party ops consoles (Hub, Delivery, Tracker, Errors, Mail, Flags, Feeds, Go link, Charts, CI cache) share React, Vite, TypeScript, Vitest, Zod and console-ui at the same versions, then diverge below that: React Router beside TanStack Router and hand-rolled routing, REST beside tRPC, raw SQLite beside Prisma, native dialogs beside Base UI. Nothing wrote the standard down, kept versions aligned, or stopped a new console starting from a bare server. This is S0 of the stack plan: write the standard down and start enforcing it. No console is migrated here.
What
package.jsoncatalogholds one version of each shared library (nothing upgraded; versions are the ones already resolved inbun.lock). The ten consoles,console-uiandops-modeldeclare them as"catalog:";bun.lockchanges only in workspace specs, not in resolved packages.catalog(verified with a localrenovate --dry-run=extract), so a JSONata custom manager inrenovate.jsonreads all entries (35 extracted). The TypeScript<7rule also matches it.check-floating-depsacceptscatalog:and checks the catalog entries themselves;check-renovate-hintsignores non-regex managers.bun run check-console-stack(package.json, turbo,verify) reads each console'spackage.jsonplusconsole-ui: required libraries, banned alternatives,catalog:use, Rust-console exceptions, and a per-app allowlist of today's deviations with reasons. A deviation with no entry fails; an entry whose deviation is gone fails, so the list only shrinks.react: true). Mail: 0 findings. Flags: 8, Feeds: 5, allcustom-rules/no-use-effect. Fixed with ref callbacks (Feeds window listeners and dialog lifecycle, Flags diff editor),<title>(Flags), and derived state (Feeds dialog reset). One scoped config override remains for Flags' Monaco JSON editor (src/client/monaco/json-editor.tsx), which mirrors controlled text and aria attributes into Monaco's own model.new-service.ts --kind web --consolewrites the standard stack: Hono on Bun with/healthz, a tRPC router with an example procedure, a PostgreSQL Prisma schema, and a Vite + React client with TanStack Router, the@trpc/tanstack-react-queryprovider and console-ui's shell, withcatalog:dependencies. The scaffolder now prettier-formats.tsxand.htmltoo.reference/console-stack, a "One stack for the consoles" section in the hosted-service model page, the--consoleflag in the add-a-hosted-service how-to, and one line inAGENTS.md.Deliberately outside the catalog:
@playwright/test(theci-playwrightpromotion rewrites each exact pin with the image digest),@types/bun, and@tanstack/react-table/@tanstack/react-formuntil first used (knip rejects unused catalog entries; the stack rules track them inCATALOG_PENDING).Demo
bun run check-console-stack, the per-app deviations that exist today (each with its allowlist reason):Allowlisted deviations per app: Hub 4, Delivery 3, Tracker 3, Errors 6, Mail 8, Flags 8, Feeds 7, Go link 6, Charts 2, CI cache 2, console-ui 2.
Verification
bun install --frozen-lockfilepasses.bunx turbo run typecheck lint test --filter=<ten consoles> --filter=@shepherdjerred/console-ui --filter=@shepherdjerred/ops-model: 56 of 56 tasks pass (Delivery 1186 tests, console-ui, ops-model, all consoles).bun run check-console-stack,check-floating-deps,renovate-hints,react-version-sync,script-coverage,check-test-standardization,check-script-migrations,check-directory-file-countspass; their and the Renovate/scaffolder suites pass.check-agent-guidancereports only the existing personal-agent drift against the live home file.bun scripts/tools/knip.ts: only the existing#generatedunresolved imports.bun run jscpdbaseline ratchet passes. Wiki builds (150 pages); new routes and the#one-stack-for-the-consolesanchor resolve.--consolepackage (scaffolded into the workspace, then removed) typechecked, linted, tested, built with Vite, and served/healthz,/trpc/helloand the client with Bun.bunx lefthook run pre-commiton staged files passes.bunx turbo run test:extended --filter=<ten consoles> --filter=@shepherdjerred/console-ui --filter=@shepherdjerred/ops-model --filter=@shepherdjerred/root-scripts --continue: 25 of 25 tasks pass.bun install, so a catalog bump leavesbun.lockfor a human to refresh), the whole-repo extended tier (the rootpackage.jsonchange makes...[origin/main...HEAD]cover every workspace; I ran it scoped to the touched workspaces instead), deployment (no runtime change).🤖 Generated with Claude Code